<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="UTF-8">
    <title>创建试卷</title>
    <link rel="stylesheet" th:href="@{/static/css/layui.css}">
    <style>
        .exist_msg{color: red;}
    </style>
</head>
<body>
    <script th:if="${session.tUser.URole eq '0'}">window.location.href="/index"</script>
    <div id="gb">
        <form class="layui-form" style="margin-top: 20px;padding-left: 40px">

            <input type="hidden" name="uId" th:value="${session.tUser.UId}">

            <div class="layui-form-item">
                <label class="layui-form-label">试卷名</label>
                <div class="layui-input-inline">
                    <input type="text" name="pName" required lay-verify="required" placeholder="请输入题目" autocomplete="off" class="layui-input pName">
                </div>
            </div>

            <div class="layui-form-item">
                <label class="layui-form-label">单选题</label>
                <div class="layui-input-inline" style="width: 130px;">
                    <!--单选题-->
                    <input type="text" name="singleQuestion" autocomplete="off" placeholder="请输入题目数量"
                           class="layui-input singleQuestion">
                </div>
                <div class="layui-form-mid">题</div>
                <div class="layui-form-mid exist_msg single_msg" ></div>
            </div>

            <div class="layui-form-item">
                <label class="layui-form-label">多选题</label>
                <div class="layui-input-inline" style="width: 130px;">
                    <!--多选题-->
                    <input type="text" name="multipleQuestion" autocomplete="off" placeholder="请输入题目数量"
                           class="layui-input multipleQuestion">
                </div>
                <div class="layui-form-mid">题</div>
                <div class="layui-form-mid exist_msg multiple_msg" ></div>
            </div>

            <div class="layui-form-item">
                <label class="layui-form-label">简答题</label>
                <div class="layui-input-inline" style="width: 130px;">
                    <!--简答题-->
                    <input type="text" name="shortQuestion" autocomplete="off" placeholder="请输入题目数量"
                           class="layui-input shortQuestion">
                </div>
                <div class="layui-form-mid">题</div>
                <div class="layui-form-mid exist_msg short_msg" ></div>
            </div>

            <div class="layui-form-item">
                <div class="layui-inline">
                    <label class="layui-form-label">开考时间</label>
                    <div class="layui-input-inline">
                        <input type="text" class="layui-input startTime" name="pBegintime" autocomplete="off" placeholder="yyyy-MM-dd HH:mm:ss">
                    </div>
                </div>
            </div>

            <div class="layui-form-item">
                <label class="layui-form-label">考试时长</label>
                <div class="layui-input-inline" style="width: 50px;">
                    <input type="text" class="layui-input pDuration" required lay-verify="required" name="pDuration" autocomplete="off">
                </div>
                <div class="layui-form-mid">分钟</div>
            </div>

            <div class="layui-form-item">
                <div class="layui-input-block">
                    <button class="layui-btn" lay-submit lay-filter="formDemo" id="butt">立即提交</button>
                    <button class="layui-btn" id="close">取消</button>
                </div>
            </div>

        </form>
    </div>

    <script type="text/javascript" th:src="@{/static/js/jquery-3.2.1.min.js}"></script>
    <script type="text/javascript" th:src="@{/static/layui.js}"></script>
    <script type="text/javascript" th:src="@{/static/js/mouseClick.js}"></script>
    <script type="text/javascript" th:src="@{/static/js/admin/addPaper.js}"></script>
</body>
</html>